﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ArmyCreator.WebCalls
{
    public class CallerResult
    {
        internal static CallerResult Create(string content)
        {
            var result = new CallerResult()
            {
                Content = content,
                IsSuccessful = true,
                ErrorMessage = null
            };

            return result;
        }

        internal static CallerResult CreateError(string message)
        {
            var result = new CallerResult()
            {
                Content = null,
                IsSuccessful = false,
                ErrorMessage = message
            };

            return result;
        }

        public bool IsSuccessful { get; private set; }

        public string Content { get; private set; }

        public string ErrorMessage { get; private set; }
    }
}
